package com.aaa.system.controller.api;

import com.aaa.entity.LoginLog;
import com.aaa.entity.SysDictData;
import com.aaa.security.annotation.MyLog;
import com.aaa.system.service.LoginLogServce1;
import com.aaa.vo.Result;
import io.swagger.annotations.Api;
import io.swagger.annotations.ApiImplicitParam;
import io.swagger.annotations.ApiImplicitParams;
import io.swagger.annotations.ApiOperation;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.PostMapping;
import org.springframework.web.bind.annotation.RequestBody;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

/**
 * @Author 崔灿
 * @Date 2023/03/01 10:28
 * @ClassName LoginLogController
 * @Description
 * @Version 1.0
 */

@Api(value = "/system/loginlog", tags = {"登录日志1"})
@RestController
@RequestMapping("/system/loginlog")
public class LoginLogController1 {

    @Autowired
    private LoginLogServce1 loginLogServce1;

    @ApiImplicitParams({
            @ApiImplicitParam(paramType = "query", dataType = "int", name = "currentPage", value = "", required = true),
            @ApiImplicitParam(paramType = "query", dataType = "int", name = "pageSize", value = "", required = true),
            @ApiImplicitParam(paramType = "body", dataType = "LoginLog", name = "loginLog", value = "", required = true)
    })
    @ApiOperation(value = "", notes = "", httpMethod = "POST")
    @MyLog(title="查询登录日志")
    @PostMapping("/loginlog")
    public Result loginlog(Integer currentPage, Integer pageSize, @RequestBody LoginLog loginLog){
        return loginLogServce1.loginlog(currentPage,pageSize,loginLog);
    }
}
